package com.mark.springboot.service;

import com.mark.springboot.entity.Admin;
import com.mark.springboot.request.LoginRequest;

import java.util.List;


/**
 * @Author: MARK
 * @Date: 2019/8/18 14:21
 * @Version: 1.0.0
 * @Description:
 */
public interface AdminService {
    /**
     * @return java.lang.Boolean
     * @create: 2019/8/19
     * @author MARK
     * @Description: 1. 登录
     */
    boolean login(LoginRequest loginRequest);

    /**
     * @return java.lang.Boolean
     * @create: 2019/8/19
     * @author MARK
     * @Description: 2. 添加用户
     */
    boolean add(Admin admin);

    /**
     * @return java.lang.Boolean
     * @create: 2019/8/19
     * @author MARK
     * @Description: 3. 重置密码
     */
    boolean resetPwd(Admin admin);

    /**
     * @return
     * @create: 2019/8/19
     * @author MARK
     * @Description: 4. 修改用户
     */
    boolean update(Admin admin);

    /**
     * @return java.util.List<com.mark.springboot.entity.Admin>
     * @create: 2019/8/19
     * @author MARK
     * @Description: 5. 获取管理员列表
     */
    List<Admin> getList();

    /**
     * @return java.lang.Boolean
     * @create: 2019/8/19
     * @author MARK
     * @Description: 6. 批量删除
     */
    boolean batchDelete(List<Integer> ids);

    /**
     * @return com.mark.springboot.entity.Admin
     * @create: 2019/8/19
     * @author MARK
     * @Description: 查找是否有该用户名
     */
    boolean getByUsername(String username);
}
